home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2005 March
/
CMCD0305.ISO
/
Software
/
Shareware
/
Utilitare
/
emu
/
Emu8086_Setup_307c.exe
/
{app}
/
Samples
/
simple_io.asm
< prev
next >
Wrap
Assembly Source File
|
2003-06-05
|
845b
|
49 lines
; This sample shows how to access
; virtual ports (00000Fh to 0FFFFh).
; These ports are emulated in
; "EmuPort.io" file (saved in
; Windows "Temp" folder).
;
; This new technology allows
; to make external add-on devices
; for Emu8086, such as led displays,
; thermostat, stepper-motor, etc...
; "DEVICES" folder contains sample
; device that works with this sample.
; (with Visual Basic source code).
; Start "Simple.exe" before running
; this sample (from "Virtual
; Devices" menu of the emulator).
#make_COM#
ORG 100h
; Write byte value "215"
; into the port 115:
mov al, 215
out 115, al
; Write word value "1234"
; into the port 117:
mov ax, 1234
out 117, ax
; Reset:
mov ax, 0
; Read byte from
; port 110 into AL:
in al, 110
; Read word from
; port 112 into AX:
in ax, 112
ret